package tedu;

import com.sun.scenario.effect.impl.sw.sse.SSEBlend_SRC_OUTPeer;

import java.util.Arrays;

public class Test {
    public static void main(String[] args) {
        String s="asf841324";
        char[] ch=new char[s.length()];
        int[] a=new int[s.length()];
        int h=0;
        for (int i = 0; i <s.length(); i++) {
            ch[i] = s.charAt(i);
            if ('0'<=ch[i]&&ch[i]<='9'){
                a[h]=ch[i]-'0';
                h++;
            }
        }

        int b[]= Arrays.copyOf(a,h);
        for (int i = 0; i < b.length; i++) {
            for (int i1 = 0; i1 < i; i1++) {
                if (b[i1] > b[i]){
                    int x=b[i];
                    b[i]=b[i1];
                    b[i1]=x;
                }
            }
        }
        System.out.println(Arrays.toString(b));

    }
}
